<template>
	<view class="box" v-if="is==0">

		<image src="https://web.78keji.cn/images/ljj/newbg.png" mode="widthFix" style="width: 100%;" @click="login">
		</image>
		<view class="d_f j_c_c">
			<image src="https://web.78keji.cn/images/ljj/newbt.png" mode="widthFix" style="width: 560rpx;"
				@click="weixin">
			</image>
		</view>

	</view>
</template>


<script>
	import {
		wxLogin,
		openSignDecrypt,
		getBanner,
		shenhe,
		getLog,
		getPhone,
		wxLogins,
		getWxKfUrl

	} from '../../api/index.js'
	import phoneApi from "../../api/phoneApi";
	export default {
		data() {

			return {
				lists: [],
				current: 0,
				showxx: true,
				tabbar: [{
						iconPath: "https://web.78keji.cn/yshimage/indexno.png",
						selectedIconPath: "https://web.78keji.cn/yshimage/index.png",
						text: '首页',
						midButton: true,
						customIcon: false
					},

					{
						iconPath: "https://web.78keji.cn/yshimage/quanyino.png",
						selectedIconPath: "https://web.78keji.cn/yshimage/quanyi.png",
						text: '热门权益',
						midButton: true,
						customIcon: false,
					}
				],

				openid: '',
				mobile: "",
				url: '',
				is: '',
				listt: [{
						img: 'https://web.78keji.cn/yshimage/shiping.png',
						name: "视频会员"
					},
					{
						img: 'https://web.78keji.cn/yshimage/stop.png',
						name: "停车券"
					},
					{
						img: 'https://web.78keji.cn/yshimage/lijianjin.png',
						name: "立减金"
					},
					{
						img: 'https://web.78keji.cn/yshimage/chongdian.png',
						name: "充电券"
					},

				],



			}
		},
		components: {

		},
		methods: {


			weixin() {
				wx.openCustomerServiceChat({
					extInfo: {
						url: this.url //客服ID
					},
					corpId: 'ww1f5608bdeca26c5a', //企业微信ID
					success(res) {
						console.log(res, "res");
					},
					fail(res) {
						uni.showToast({
							title: '请联系管理员获取id',
							icon: 'none', //将值设置为 success 或者 ''
							duration: 2000 //持续时间为 2秒
						})
					}
				})

			}


		},
		onLoad(option) {
			if (option.id) {
				getWxKfUrl({
					id: option.id
				}).then((res) => {
					this.url = res.data.url
				})
			} else {
				uni.showToast({
					title: '请联系管理员获取id',
					icon: 'none', //将值设置为 success 或者 ''
					duration: 2000 //持续时间为 2秒
				})
			}

			shenhe({
				pid: 2,
				ver: 709
			}).then((res) => {
				this.is = res.data.is
			})




		},
		watch: {

		},
		computed: {

		}
	}
</script>

<style scoped lang='scss'>
	.box {
		position: relative;
		height: 100%;
		overflow: hidden;
		background-color: #ffede1;
	}

	.bottom {
		width: 750rpx;
		padding: 45rpx 24rpx 33rpx 24rpx;
		background: #F7F7F7;
		border-radius: 41rpx;

	}

	.bottoms {
		width: 750rpx;
		padding: 45rpx 24rpx 33rpx 24rpx;

		border-radius: 41rpx;

	}

	.bossx {
		background-image: url('https://web.78keji.cn/yshimage/bg.png');
		background-size: 100% 100%;
		height: 497rpx;
	}

	.boss {
		padding: 25rpx 23rpx 0 40rpx;


	}

	.login {
		width: 120rpx;
		height: 42rpx;
		background: #000000;
		border-radius: 20rpx;
		color: white;
		font-size: 24rpx;
		line-height: 42rpx;
	}

	.banner {
		padding: 0 24rpx 24rpx 24rpx;
		background-color: white;
		margin-top: -20rpx;

	}

	.columnx {
		display: flex;
		flex-wrap: wrap;
		justify-content: space-between;
		align-items: center;
		height: 235rpx;
		border-radius: 10rpx;
		background: #FFFFFF;
	}

	.bindx {
		width: 25%;



		padding: 14rpx 0 14rpx 0;
		display: flex;
		flex-direction: column;
		align-items: center;
	}

	.bracelet {
		width: 96rpx;
		height: 96rpx;
	}

	.binding {
		margin-top: 20rpx;
	}

	.second {
		font-size: 30rpx;
		font-weight: bold;
		display: flex;
		justify-content: center;
	}

	.card {
		padding: 0 14rpx 0 14rpx;
	}

	.images {
		padding-top: 33rpx;
		padding-left: 12rpx;

	}
</style>